<extend name="Layout/ins_popup" />
<block name="content">
	<input type="hidden" name="val" id="val">
	<input type="hidden" name="name" id="name">
	<div class="popup-header ">
		<div class="pull-left">
			<h1>导入审批单</h1>
		</div>
		<div class="pull-right">
			<a id="btn_save" class="btn">确定</a>
			<a onclick="myclose();" class="btn btn-return">关闭</a>
		</div>
	</div>
	<div class="popup-body" style="height: 420px;overflow-y: auto;">
		<form id="form_data" name="form_data" method="post" >
			<input type="hidden" name="opmode" id="opmode" value="add">
			<div class="layui-form-item col-xs-12">
				<label class="col-xs-3 input-label" for="short">审批单*：</label>
				<div class="col-xs-9">
					<select name="out_rule" class="input col-11">
						<option>全部</option>
						{:fill_option($out_rule)}
					</select>
				</div>
			</div>
			<div class="layui-form-item col-xs-12">
				<label class="col-xs-3 input-label" for="name">开始日期*：</label>
				<div class="col-xs-9">
					<input class="input input-date" type="text" id="start_date" name="start_date" check="required" info="选择开始日期">
				</div>
			</div>
			<div class="layui-form-item col-xs-12">
				<label class="col-xs-3 input-label" for="short">结束日期*：</label>
				<div class="col-xs-9">
					<input class="input input-date" type="text" id="end_date" name="end_date" check="required" info="选择结束日期">
				</div>
			</div>
		</form>
	</div>
</block>
<block name="js">
	<script type="text/javascript">
		function save() {
			if (check_form("form_data")) {
				var vars = $("#form_data").serialize();
				send_ajax("{:url('import_flow')}", vars, function(data) {
					if (data.status) {
						ui_alert(data.info, function() {
							parent.location.reload(true);
							myclose();
						});
					} else {
						ui_error(data.info);
					}
				});
			}
		}
	</script>
</block>